package com.config;

import org.springframework.boot.autoconfigure.data.redis.JedisClientConfigurationBuilderCustomizer;
import org.springframework.data.redis.connection.jedis.JedisClientConfiguration;

import java.time.Duration;

public class MyJedisClientConfigruationCustomizer implements JedisClientConfigurationBuilderCustomizer {
    @Override
    public void customize(JedisClientConfiguration.JedisClientConfigurationBuilder clientConfigurationBuilder) {
        //配置完毕后就可以结束不需要配置build方法
        clientConfigurationBuilder.clientName("asdfsads")
                .connectTimeout(Duration.ofSeconds(10));
    }
}
